package com.jndv.phoneconfig;

import com.chad.library.adapter.base.BaseQuickAdapter;
import com.chad.library.adapter.base.BaseViewHolder;
import com.jndv.phoneconfig.command.PairResult;

import java.util.List;

public class DeviceAdapter extends BaseQuickAdapter<PairResult, BaseViewHolder> {

    public DeviceAdapter(int layoutResId, List<PairResult> data) {
        super(layoutResId, data);
    }

    @Override
    protected void convert(BaseViewHolder baseViewHolder, PairResult s) {
        baseViewHolder.setText(R.id.tv_name,s.deviceName);
        baseViewHolder.setText(R.id.tv_state,s.isPair?"已连接":"未连接");
    }
}
